﻿using System;
using System.IO;
using System.Reflection;
namespace Moonlite.ExtensionApi
{
    public static class AssemblyExtensions
    {
        public static string GetPath(this Assembly assembly)
        {
            string codeBase = assembly.CodeBase;
            if (codeBase.ToLower().StartsWith("file://"))
            {
                codeBase.Substring("file://".Length);
            }
            return codeBase;
        }
    }
}
